package Wy.Demmo02;

public class Person2 {
    private int age;

    public void setAge(int age) {
        if (age > 0 || age < 120){
            System.out.println("您输入的年龄不合法");

        }else {
            this.age = age;
        }

    }
}

